Fermat Pseudoprime

The motivation for the definition of a pseudoprime comes from Fermat's little theorem. Specifically, we consider the statement of the converse of Fermat's little theorem, which we have no justification in claiming is a true statement:

Given a prime p and number a where gcd(a,p)=1, if ap11(modp), then p is prime.

This statement is not true. Consider the following counterexample:

Example

n=15 is a non prime number which satisfies:

an11(modn)

when a=4.

4151=414=167171(mod15)

Numbers which satisfy this property are called Fermat pseudoprimes, because with respect to Fermat's little theorem, they act like prime numbers, but are not.

Definition

If n is a composite number which satisfies:

ap11(modn)

for some aZ, then n is called a Fermat pseudoprime to the base a.

Hence, in the language of this definition, 15 is a Fermat pseudoprime to the base 4.

Numbers which are pseudoprime to all coprime bases are called Carmichael numbers.